package com.usst.service.impl;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.usst.entity.PostAnswer;
import com.usst.repository.PostAnswerRepository;
import com.usst.service.PostAnswerService;

@Service
public class PostAnswerServiceImpl implements PostAnswerService{
	
	@Autowired
	private PostAnswerRepository postAnswerRepo;

	@Override
	public PostAnswer save(PostAnswer postAnswer) {
		return postAnswerRepo.save(postAnswer);
	}

	@Override
	public PostAnswer update(PostAnswer postAnswer){
		return postAnswerRepo.save(postAnswer);
	}

	@Override
	public void delete(PostAnswer postAnswer) {
		postAnswerRepo.delete(postAnswer);
	}

	@Override
	public PostAnswer findOne(Long postId) {
		return postAnswerRepo.findOne(postId);
	}

}
